package com.aiyige.base.eventbus;

import com.aiyige.base.db.table.InfoModel;
import com.aiyige.base.db.table.TraingClassDBModel;

/**
 * Created by zhuyakun on 2017/12/6.
 */

public class EventEditInfoFinish {
    public static final int RESULT_OK = 1;
    public static final int RESULT_CANCEL = 2;
    int resultCode;
    InfoModel infoModel;

    public EventEditInfoFinish() {
    }

    private EventEditInfoFinish(Builder builder) {
        setResultCode(builder.resultCode);
        setInfoModel(builder.infoModel);
    }

    public static Builder newBuilder() {
        return new Builder();
    }

    public int getResultCode() {
        return resultCode;
    }

    public void setResultCode(int resultCode) {
        this.resultCode = resultCode;
    }

    public InfoModel getInfoModel() {
        return infoModel;
    }

    public void setInfoModel(InfoModel infoModel) {
        this.infoModel = infoModel;
    }

    public static final class Builder {
        private int resultCode;
        private InfoModel infoModel;

        private Builder() {
        }

        public Builder resultCode(int val) {
            resultCode = val;
            return this;
        }

        public Builder infoModel(InfoModel val) {
            infoModel = val;
            return this;
        }

        public EventEditInfoFinish build() {
            return new EventEditInfoFinish(this);
        }
    }
}
